package chen.web.controller.forum.form;

import chen.web.util.ContentFilter;

public class VoteForm {

	private String[] options;
	private boolean publicVoters;
	private int optionalQuantity = 1;
	private int days;

	public String[] getOptions() {
		return options;
	}
	public void setOptions(String[] options) {
		for(int i=0; i<options.length; i++){
			options[i] = ContentFilter.escapeXml(options[i]);
		}
		this.options = options;
	}
	public boolean isPublicVoters() {
		return publicVoters;
	}
	public void setPublicVoters(boolean publicVoters) {
		this.publicVoters = publicVoters;
	}
	public int getOptionalQuantity() {
		return optionalQuantity;
	}
	public void setOptionalQuantity(int optionalQuantity) {
		if(optionalQuantity < 1)
			optionalQuantity = 1;
		else
			this.optionalQuantity = optionalQuantity;
	}
	public int getDays() {
		return days;
	}
	public void setDays(int days) {
		this.days = days;
	}
}
